package com.ccsu.joysport.repository;

import com.ccsu.joysport.entity.StudentActivity;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;
import java.util.Optional;

public interface StudentActivityRepository extends JpaRepository<StudentActivity, Integer> {
    Optional<StudentActivity> findByActivityIdAndStudentId(String activityId, String studentId);
    List<StudentActivity> findByStudentId(String studentId);
    boolean existsByStudentId(String studentId);
    List<StudentActivity> findByActivityId(String activityId);


    List<StudentActivity> findByActivityIdIn(List<String> activityIds);
}
